<div id='el_container_${fn.id}'>
<#assign formId = parameters.id?default('_' + fn.id)/>
<@s.form id="%{#ps.id}Form" action="${fn.linkNoBase(fn.replaceAction(ps.targetAction,'updateList'),false)}" validate="false">
	<script>
		<#assign textId = 'el_' + fn.id/>
		Ext.onReady(function(){
			new Ext.Panel({
				id:'input_${fn.id}',
				renderTo: '${textId}',
				height: 150,
				frame: true,
				border:false,
				autoWidth:true,
				autoScroll:true,
				html:"<font size=2>${fn.encodeHTML(stack.findValue('execute.richContent'))}</font>"
			});
		});
	</script>
	<div id='${textId}'></div>

	<@s.actionerror />
	<input type="hidden" name="_type" value="${fn.modelName}"/>
	<@s.hidden id="${fn.id}" name="model.id"/>
	<@s.hidden id="${fn.id}" name="model.party.id"/>
	<@s.hidden id="${fn.id}" name="model.eventItem.id"/>
	<@s.hidden id="${fn.id}" name="model.event.id"/>
		
	<table border="0" cellpadding="0" cellspacing="0">
	  <tr>
	    <td>
	    	<@cs.element type="text" name="model.content" size=80 theme="simple" cssClass="x-form-text x-form-field"/> &nbsp;
		</td>
		<td>
		</td>
	  </tr>
	  <tr>
	     <td>
	    	<@cs.element type="text" name="model.content" size=80 theme="simple" cssClass="x-form-text x-form-field"/> &nbsp;
		</td>
		<td>
			<@cs.element id="${btnId}" type="button.ftl" name="add" label="${btnLabel}" onclick="submitLog($('el_${btnId}'))"/>
	    </td>
	  </tr>
	  
     <@cs.mark name="butonArea">
		<script>
			Ext.onReady(function(){
				var cmp_submit = new Ext.Button({
					id:'submit_${formId}',
					name:'model.submit',
					text:'<@s.text name='action.save'/>',
					renderTo: 'el_submit_${formId}'
				});
				cmp_submit.on('click', function(){
					submitPage($('el_submit_${formId}'));
				});
				
				var cmp_cancel = new Ext.Button({
					id:'cancel_${formId}',
					name:'model.cancel',
					text:'<@s.text name='action.cancel'/>',
					renderTo: 'el_cancel_${formId}'
				});
				cmp_cancel.on('click', function(){
					closeTabPage($('el_cancel_${formId}'));
				});
			});
		</script>
		  <tr>
		    <td><div id='el_submit_${formId}' extType='button'></div></td>
		    <td width="5px"></td>
		    <td><div id='el_cancel_${formId}'></div></td>
		  </tr>
	</@cs.mark>
	</table>
</@s.form>
</div>